home *** CD-ROM | disk | FTP | other *** search
/ Carousel Volume 2 #1 / carousel.iso / mactosh / hc / growthre.sit / Growth Records / card_27442.txt < prev    next >
Text File  |  1988-02-06  |  9KB  |  170 lines

  1. -- card: 27442 from stack: in
  2. -- bmap block id: 30528
  3. -- flags: 0000
  4. -- background id: 11213
  5. -- name: Comment 4
  6. ----- HyperTalk script -----
  7. on openCard
  8.   color cyan, black
  9.   go to this card
  10.   color red,black
  11.   show card field id 1
  12. end openCard
  13.  
  14. on CloseCard
  15.   set lockScreen to true
  16.   color normal
  17.   hide card field id 1
  18.   set lockScreen to false
  19. end CloseCard
  20.  
  21.  
  22.  
  23.  
  24. -- part 1 (field)
  25. -- low flags: 80
  26. -- high flags: 0007
  27. -- rect: left=0 top=29 right=307 bottom=512
  28. -- title width / last selected line: 0
  29. -- icon id / first selected line: 0 / 0
  30. -- text alignment: 0
  31. -- font id: 20
  32. -- text size: 12
  33. -- style flags: 256
  34. -- line height: 16
  35. -- part name: Comment 4
  36. ----- HyperTalk script -----
  37. --
  38. -- Field script to allow special handling of option-clicked
  39. -- words in ANY text field, whether locked or unlocked
  40. --
  41. -- Guy Kuo, University of Nevada School of Medicine
  42. -- December 13, 1987
  43. --
  44. -- Use this script freely in your owns stacks but please retain the
  45. -- credit line
  46. --
  47. On MouseWithin -- UNSOM technique by Guy Kuo, December 13, 1987
  48.   -- If the the option key is depressed, set the cursor to indicate
  49.   -- we are in a special mode.  While the option key continues to be
  50.   -- depressed, and the mouse is within the target field, wait for
  51.   -- mouseDowns.  If one occurs, Pick up the word by clicking at the
  52.   -- last MouseLoc twice and getting the selection.
  53.   -- If the selection is not empty, do something with it.  In this demo,
  54.   -- we put it into another field.  Finally, click outside of the field
  55.   -- to avoid looping.  Hopefully, (-1,-1) is outside of all active
  56.   -- objects.
  57.   --
  58.   -- While editing such a field, entry of Optioned characters from
  59.   -- the keyboard no longer requires movement of the mouse outside of
  60.   -- the field.  However, the optioned characters do not appear until
  61.   -- after the option key is released
  62.  
  63.   if the OptionKey is down then
  64.     global theselection
  65.     if the locktext of the target is true then
  66.       put true into DidUnlock
  67.       set locktext of target to false
  68.     else
  69.       put false into DidUnlock
  70.     end if
  71.     set the cursor to 2
  72.     repeat while (the OptionKey is down) and (item 1 of the rect of target <= item 1 of the mouseLoc) and (item 1 of the mouseLoc <= item 3 of the rect of target) and (item 2 of the rect of target <= item 2 of the mouseLoc) and (item 2 of the mouseLoc <= item 4 of the rect of target)
  73.       if the Mouse is down then
  74.         click at the MouseLoc
  75.         click at the ClickLoc
  76.         if the selection <> empty then
  77.  
  78.           -- or do something useful
  79.           put the selection into theselection
  80.           --the hidden field to be selected
  81.           if the selection is "selected" then
  82.             color magenta,black
  83.             show card field the selection
  84.             show card button "OK"
  85.           end if
  86.           --put the next useful function here
  87.  
  88.         end if
  89.         click at -1,-1
  90.       end if
  91.     end repeat
  92.     if DidUnlock then
  93.       set the locktext of the target to true
  94.     end if
  95.   end if
  96. end MouseWithin
  97.  
  98.  
  99.  
  100. -- part 5 (field)
  101. -- low flags: 80
  102. -- high flags: 0002
  103. -- rect: left=1 top=95 right=250 bottom=477
  104. -- title width / last selected line: 0
  105. -- icon id / first selected line: 0 / 0
  106. -- text alignment: 0
  107. -- font id: 20
  108. -- text size: 12
  109. -- style flags: 256
  110. -- line height: 16
  111. -- part name: selected
  112.  
  113.  
  114. -- part 6 (button)
  115. -- low flags: 80
  116. -- high flags: A003
  117. -- rect: left=435 top=228 right=248 bottom=470
  118. -- title width / last selected line: 0
  119. -- icon id / first selected line: 0 / 0
  120. -- text alignment: 1
  121. -- font id: 0
  122. -- text size: 12
  123. -- style flags: 0
  124. -- line height: 16
  125. -- part name: OK
  126. ----- HyperTalk script -----
  127. on mouseUp
  128.   global theselection
  129.  
  130.   hide card field theselection
  131.   hide card button "OK"
  132.   color red
  133. end mouseUp
  134.  
  135.  
  136.  
  137. -- part contents for card part 1
  138. ----- text -----
  139.      This Hypercard stack and its companion, "Patient Names" has essential 5 functions:
  140.               1. "Patient Names" stores information essential to the tracking of individual patients.  As such, all additional cards related to a given patient are identified by the information in this card.  Therefore, enter all data related to a new individual or patient in this stack.  This will provide a consistent format for identification of new cards for the patient.  The critical pieces of information include last name, first name, sex (m/f), hospital or idenfication number (like 1 or 2) and date of birth in the format shown.
  141.               2. A storage place for anthropromorphic and sexual maturation data for individual children in "Growth Records";
  142.               3. The primary data can be plotted on charts of standard construction;
  143.               4. A quick electronic growth chart where individual or few growth points can be plotted and
  144.               5. The pattern of growth can be visually compared with recognizable patterns of abnormal growth.  Selection of the most similar pattern brings forth a brief clinical description.
  145.  
  146. DATA ENTRY:
  147.     Entering data into the growth record cards is relatively straight forward.  Below the column "Date" you will notice a line and below that it says "Enter date".  On the same level, you will see weight, height, bone age and sex maturation fields.  These fields (data entry fields) are where you should enter all of your data.  Upon selection of the button enter data, the cursor is placed in the first field called "enter date".  You may move the cursor to the next field by simply using the tab key.  Once all the information for a given date is completed, click on the "enter data" button and the program will move the data into the last line of the appropriate fields above, clear the current data entry fields and move the cursor back to the first data entry field.  If this field is empty, you are told so.  Once this field contains information (correct or otherwise), the information in the data entry fields will be transferred to the next available line in the appropriate column.  Information should be entered from young (at the top) to old (toward the bottom) and should be entered in a sequential fashion.  Dates and growth data which are not in the correct time sequence may behave in a very unpredictable fashion, particularly for calculations of growth velocity data.
  148.  
  149.     Only one of the fields, "enter date" has a special format.  The date should be entered with the MM/DD/YR format.  The other data should be entered based on the units which you have selected*.  The remainder of the data entry fields will accept any kind of decimal value.
  150.  
  151.     WARNING:  Once data is entered into the card, insertion of a new data point in the middle of the existing data will create huge problems.  The most significant is that other information may not correspond to the correct date.  USE THE EDIT DATA BUTTON WITH EXTREME CAUTION AND DO NOT DELETE LINES OF A PARTICULAR FIELD!  IF YOU WANT TO CLEAR A LINE, THEN USE THE CLEAR TEXT COMMAND IN HYPERCARD.  
  152.  
  153. FUNCTIONS BUTTON
  154.     The button, when selected, results in a pop up menu with various functions.  Some of these functions are explained elsewhere.
  155.  
  156. Plot data:  This function uses the data provided on the individual card and plots the information on sex appropriate graphs.  The plots which are available include stature
  157. (length), weight, weight for height and height velocity.  On the stature and weight graphs, there is a "Quickplot" button (upper left corner inside the box) which will plot the data shown in the box. You can edit the data in this box and plot several points on the curve.   With the function, it is not necessary for you to enter the information on the individual into the permanent files; however, none of the information which you put into this box will be saved.  The Clear button simply clears the plotting screen.  
  158.  
  159. On the stature plots, you will also find a button called "Quick Evaluation."  The results returned by this button include a prediction of final adult height by two methods.  A bone age is required for these calculations and if one exists for the most recent data, then it will be inserted into the Bone value.  Parent's height is another measurement required for the RWT method.  If parent's heights are not supplied on the patient's card, then the population average is used.  The mean target height and 2 standard deviations for the child is displayed on the graph as a bold bar on the far right side of the graph.  Finally, a button appears (a talking person) at the end of the quick evaluation.  This button, if selected, will do a computerized diagnostic evalution of the growth data based on the article of Zachman, M and Nessi, P (1984) Clinical Pediatrics 23:609-616.  Finally you can return to the growth record card by clicking on the growth icon at the bottom of the card.  
  160.  
  161.  CALCULATE AGES:
  162.     The function calculates the ages for each date entered.  This will be useful if you have incorrectly entered the date and need to recalculate the age
  163.  
  164. CALCULATE HEIGHT VELOCITY:
  165.    Displays the growth velocity field and calculates the growth velocity based on the specified minimum interval of time.            
  166.  
  167. -- part contents for card part 5
  168. ----- text -----
  169. Below the columns titled "weight" and "height" are displayed the units of measure.  If you click on the displayed units of measure, the other unit of measure (either English or metric) will be displayed and the values in the attached column will be re-calculated.  If the column is empty, you only switch the displayed units. 
  170.